The present invention relates to graphical image processing in a computer system and, in particular, to a mechanism for capturing computer generated motion video images.
As processing and storage capacity of today""s computers and, in particular, personal computers, continue to increase significantly, generation by computers of motion video images is becoming ever increasingly, common and popular. Users of such computers have access to a wide variety of computer programs which are capable of generating sophisticated and complex motion video images. Examples of such images include (i) three-dimensional, perspective projection, motion graphical images representing inter-operation of parts designed using computer aided design/computer aided manufacturing (CAD/CAM) systems; (ii) computer-generated special effects for use in television program production, primarily sports and news; (iii) computer-generated animations which are designed as artistic and/or entertaining audio-visual works in their own right. Computers which generate motion video images from model data are sometimes referred to herein as authoring programs.
In addition, growing popularity of very large computer networks such as the Internet and networks having multimedia content such as the World Wide Web has cultivated a very strong demand for motion video images in a sufficiently compact form that such motion video signals can be transported through such networks. Accordingly, motion video image formats such as AVI, MPEG, QuickTime, and Animated GIF have become very popular recently and computer software readers which can receive, decode and display such motion video images have been installed in a multitude of client computer systems connected through such networks.
Many of the computer programs which generate motion video images do so from model data which define the animation and can only reproduce the motion video images by re-generating the motion video images from the same model data In other words, many authoring programs provide no mechanism by which a user of an authoring program can record and store the computer-generated motion video image either (i) for subsequent playback without having to recreate a particular operating environment of the program or (ii) for delivery through a multimedia-based network protocol using a compact motion video image format such as AVI, MPEG, QuickTime, or Animated GIF. While it may be possible to re-design authoring programs to store motion video images which are generated, the user of such an authoring program frequent lacks either the ability, inclination, or access to make such changes.
Some attempts have been made to intercept and store graphics display instructions produced by a CAD/CAM program to cause display of the motion video image produced by the program in a computer display device. By intercepting and storing such graphics display instructions, such instructions can be subsequently retrieved and re-executed to re-display the motion video image in the computer display device. One such system is the Shared Library Interposer (SLI) developed by Sun Microsystems, Inc. of Mountain View, Calif. SLI served its intended purpose, namely, capturing a sequence of graphics display instructions for analysis and error detection and correction, very well. However, SLI is poorly adaptable to the purpose of recording motion video signals for subsequent playback or delivery.
First, since the motion video image is reproduced by exact replication of the precise graphical display instructions, each and every such graphical display instruction must be executed and the order in which the graphical display instructions are executed must be the same as the order in which the instructions were executed by the authoring program. Even such instructions as those which open the graphics device for access and allocate various states and resources must be executed. Such limits the playback of the motion video image to precisely the same computer display device on which the authoring program displayed the motion video image. In addition, the motion video image can only be reproduced from the very beginning, i.e., beginning portions of the motion video image cannot be omitted from the recorded motion video image.
Second, since each and every graphical display instruction is stored for subsequent re-execution, a tremendous amount of computer memory is required to store the recorded motion video image. Typically, approximately one gigabyte or more is required to store a moderately complex motion video signal. Thus, motion video images which are recorded in this manner are too large to transmit through practically any currently available network medium What is needed therefore is a mechanism by which motion video images generated by an authoring program can be recorded and stored in a compact format which is suitable for delivery through a computer network. The mechanism should enable the recording to begin some time into the motion video image such that beginning portions of the motion video image can be omitted from the recorded motion video image. In addition, the format of the motion video image should be portable, i.e., should enable re-display of the motion video image on computer display devices and platforms other than the computer display device and platform for which the motion video image was generated by the authoring program.
In accordance with the present invention, a motion video image capture (MVIC) process monitors interaction between an authoring process and a graphics display library and captures each frame of the motion video image created by the authoring process. By capturing each frame of the motion video image created by the authoring process, the MVIC process can recreate the motion video image without storing or re-executing, the specific graphics display instructions executed by the authoring process. In addition, the frames can be collectively stored in a compact, standard motion video image format, e.g., any of the known MPEG, AVI, QuickTime, or Animated GIF formats, which can then be easily delivered through a network such as the Internet using a standard multimedia protocol such as the World Wide Web. Alternatively, the frames can be stored as individual graphics images in a standard, compact graphical image format such as any of the known JPEG, GIF, or TIFF formats.
Further in accordance with the present invention, the MVIC process monitors interaction between the authoring, process and the graphics display library using a conventional mechanism known as interposing. By interposing the MVIC process between the authoring process and the graphics display library, the MVIC process can monitor procedures of the graphics display library invoked by the authoring process.
The MVIC process monitors procedures of the graphics display library invoked by the authoring process for a target procedure which is invoked either at the completion of display of a frame or prior to display of a new frame. Such a target procedure can be, for example, a graphics pipeline flush or end-of-frame procedure which causes all graphical image data which is queued for transfer to a frame buffer to be immediately transferred to the frame buffer. Such graphics pipeline flush procedures are known by various identifiers in various respective implementations but serve the same primary purpose, i.e., are invoked by the authoring process only when a frame of the motion video image is complete and should therefore be displayed for the user prior to generation and display of the next frame of the motion video image. Other procedures which can be used as a target procedure also include (i) a swap buffer procedure which causes the contents of a temporary buffer to be loaded into the frame buffer and (ii) a new frame procedure which indicates that the last frame is complete and should be displayed and a buffer should be initialized for display of a new frame. Accordingly, the MVIC process interprets invocation of any such target procedure as an indication that the frame buffer contains pixel data representing a completed frame of the motion video image. The MVIC process therefore retrieves pixel data from the frame buffer in response to detection of invocation of the target procedure to thereby capture the completed frame.
Once the MVIC process captures a completed frame of the motion video image from the frame buffer, the MVIC process stores the captured frame as a frame in a stored motion video image in a compact, standard motion video image format or still image format.
Thus, existing authoring processes can be used to generate and display motion video images and those motion video images can be easily and efficiently captured and stored in a compact, standard format. Accordingly, the motion video image can be delivered through a network such as the Internet and replayed remotely by a receiving computer system. In addition, the capture and storage of the motion video image is accomplished without modification to the authoring process. As a result, any of a multitude of currently available authoring processes can generate and display motion video images which can be stored for subsequent distribution through a network or for subsequent local redisplay without modification of the authoring processes and notwithstanding failure of the authoring process to provide for such capture and storage.